<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <script src="https://unpkg.com/vue@3/dist/vue.global.js"></script>
</head>
<body>

  <div id="app">
    <input type="text" ref="inp">
  </div>

  <script>
  const { createApp, onMounted, ref }  = Vue;
  const app = createApp({
    setup(){ 

        const inp = ref(null);

        onMounted(()=>{
            setTimeout(()=>{
                inp.value.focus();
            }, 1000)
        })

        return{
            inp
        }
       }
  });


  app.mount('#app');

  </script>

</body>
</html>